#include <stdio.h>
#include <string.h>
char* reverseLeftWords(char* s, int n) {
    int sz = strlen(s);
    int left = 0, right = n - 1;
    while (left < right)
    {
        char tmp = s[left];
        s[left] = s[right];
        s[right] = tmp;
        left++, right--;
    }
    while (n > 0)
    {
        char tmp = s[n - 1];
        for (int i = n; i < sz; i++)
        {
            s[i - 1] = s[i];
            if (i == sz - 1)
            {
                s[i] = tmp;
            }
        }
        n--;
    }
    return s;
}
int main()
{
    char str[] = "irloseumgh";
    int n = 6;
    char* str1 = reverseLeftWords(str, n);

}